home *** CD-ROM | disk | FTP | other *** search
/ Delphi Programmer's Power Pack / Delphi Volume 1.iso / e_to_l / grabicon / unit1.pas < prev   
Encoding:
Pascal/Delphi Source File  |  1996-09-15  |  690 b   |  37 lines

  1. unit Unit1;
  2.  
  3. interface
  4.  
  5. uses
  6.   SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
  7.   Forms, Dialogs, Buttons, ExtCtrls, Grabicon;
  8.  
  9. type
  10.   TForm1 = class(TForm)
  11.     GrabIconImage1: TGrabIconImage;
  12.     SpeedButton1: TSpeedButton;
  13.     SaveDialog1: TSaveDialog;
  14.     procedure SpeedButton1Click(Sender: TObject);
  15.   private
  16.     { Private declarations }
  17.   public
  18.     { Public declarations }
  19.   end;
  20.  
  21. var
  22.   Form1: TForm1;
  23.  
  24. implementation
  25.  
  26. {$R *.DFM}
  27.  
  28. procedure TForm1.SpeedButton1Click(Sender: TObject);
  29. begin
  30.      if( SaveDialog1.Execute ) then
  31.      begin
  32.           GrabIconImage1.Picture.SaveToFile( SaveDialog1.FileName )
  33.      end;
  34. end;
  35.  
  36. end.
  37.